package com.zte.claa.inficombo.csa.app.service.gprs.bean;

public class GPRSMsgHead {
	public static final short GPRS_REGREQ  = 0x01;	
	public static final short GPRS_HBREQ = 0x02;	
	public static final short GPRS_UPLINK  = 0x03;

	private int msgtype = 0x00;
	private String deveui = "";
	private int msgLen = 0;
	private String iccid = "";
	private int rssi = -1;
	
	/**
	 * 头部字节数（固定5个字节）
	 * @return
	 */
	public static int getHeadSize(){
		return 9;
	}
	
	public GPRSMsgHead(){
		
	}
	
	public int getMsgtype() {
		return msgtype;
	}

	public void setMsgtype(int msgtype) {
		this.msgtype = msgtype;
	}

	public String getDeveui() {
		return deveui;
	}

	public void setDeveui(String deveui) {
		this.deveui = deveui;
	}

	public int getMsgLen() {
		return msgLen;
	}

	public void setMsgLen(int msgLen) {
		this.msgLen = msgLen;
	}
	
	public String getIccid() {
		return iccid;
	}

	public void setIccid(String iccid) {
		this.iccid = iccid;
	}

	public int getRssi() {
		return rssi;
	}

	public void setRssi(int rssi) {
		this.rssi = rssi;
	}

	public String toString(){
		StringBuilder sb = new StringBuilder();
		sb.append("msgtype=").append(this.msgtype).append(";\n");
		sb.append("deveui=").append(this.deveui).append(";\n");
		sb.append("MsgLen=").append(this.msgLen).append(".");
		return sb.toString();
	}
}
